﻿using System;
using System.Runtime.InteropServices;
/*空闲内存链表*/
//[StructLayoutAttribute(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 1)]
public struct mr_free_mem_st
{
	public uint next; //下个节点位置，这个位置是相对于基地址的
	public uint size; //该段空闲内存的大小
}

/*内存状态*/
//[StructLayoutAttribute(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 1)]
public struct mr_mem_state_t
{
	public uint @base;        //内存基址
	public uint len;         //内存长度
	public uint end;         //内存终址
	public uint left;        //剩余内存
	public uint min;         //内存底址
	public uint top;         //内存峰值
	public mr_free_mem_st free; //空闲内存存链表，它指向的是空闲链表的开始节点
}
